Encompasses all API of component NilkinsWinUi. More...
Classes | |
class | AlignmentUtils |
Holds static utility functions to interact with the ALIGNMENT enum class values. More... | |
class | Button |
A graphical button. More... | |
struct | ChangeEventData |
Data holder for a change event. More... | |
struct | CharEventData |
Data holder for a char event. More... | |
class | CheckBox |
A graphical check box. More... | |
struct | ClickEventData |
Data holder for a click event. More... | |
class | Color |
Represents a color, with 4 channels. More... | |
class | ComboBox |
A graphical combo box. More... | |
class | Component |
Base class for any graphical component. More... | |
class | ComponentManager |
Manages the components within nkWinUi. More... | |
class | ContentLoader |
Allows to export and import content through their declaration files. More... | |
class | ContextMenu |
A graphical context menu. More... | |
class | Cursor |
WIP. More... | |
class | CursorManager |
WIP. More... | |
class | CursorUtils |
A utility class to interact with the cursor. More... | |
class | EditBox |
A graphical single line edit box. More... | |
class | FileExplorer |
A graphical file explorer. More... | |
class | Font |
Offers an interface to work with fonts [WIP]. More... | |
class | FontManager |
Manages the fonts in the component [WIP]. More... | |
class | GridLayout |
Implements a layout organizing children components in a grid. More... | |
class | GroupBox |
A graphical group box. More... | |
struct | HandledEventData |
Data holder for a handled event. More... | |
class | InputDescriptor |
Describes an input event. More... | |
class | InputSystem |
Input system, centralizing default behaviour for the input. More... | |
struct | KeyEventData |
Data holder for a key event. More... | |
class | Layout |
Represents a layout to organize sub-windows in a window. More... | |
class | ListBox |
A graphical list box. More... | |
class | LogManager |
Responsible for logging all messages from the component. More... | |
class | LogWin |
A graphical log window, where lines can be added like a console log. More... | |
class | MainSystem |
The main system of the component. More... | |
struct | MouseMoveEventData |
Data holder for a mouse move event. More... | |
class | MultiLineEdit |
A graphical multi line edit box. More... | |
struct | NotificationPositionDescriptor |
Describes the position constraints a notification or popup should satisfy. More... | |
class | Notificator |
Gather notification and popup related functions. More... | |
struct | PopupCustomDescriptor |
Describes how a custom popup should behave. More... | |
struct | PopupYesNoDescriptor |
Describes the behaviour a yes / no popup should have. More... | |
class | ProgressBar |
WIP. More... | |
class | RelativeLayout |
Implements a layout positioning its children components relative to each other. More... | |
class | RelativePositionUtils |
Holds static utility functions to interact with the RELATIVE_POSITION enum class values. More... | |
class | ScrollBar |
A graphical scroll bar. More... | |
class | Slider |
A graphical slider. More... | |
class | Static |
A graphical static text zone. More... | |
class | StructToString |
Offers utilities to convert from structures or enums to strings, and vice versa. More... | |
class | TabWindow |
A graphical tab window. More... | |
class | Theme |
A theme used to style the windows in the component. More... | |
struct | ThemeColors |
Information about all the colors a theme will need. More... | |
class | ThemeManager |
Manages the themes within the component. More... | |
class | ToolBar |
A ToolBar in which items can be added to offer different capabilities. More... | |
class | TreeView |
A graphical tree view window. More... | |
struct | WheelEventData |
Data holder for a wheel event. More... | |
class | Window |
A graphical window, made for general purpose. More... | |
Typedefs | |
using | mouseMoveCallback = std::function< bool(Component *caller, int absX, int absY, int relX, int relY, int moveX, int moveY)> |
Used by components for a mouse moved event. More... | |
using | mouseClickCallback = std::function< bool(Component *caller, const ClickEventData &eventData)> |
Used by components for a mouse click event. More... | |
using | mouseLeaveCallback = std::function< bool(Component *caller, const nkMaths::Point &absCoords)> |
Used by components when the mouse leaves their area. More... | |
using | keyDownCallback = std::function< bool(Component *caller, KEY_CODE keyCode, bool autoRepeated)> |
Used by component when a keyboard key is pressed down. More... | |
using | keyUpCallback = std::function< bool(Component *caller, KEY_CODE keyCode)> |
Used by component when a keyboard key is released. More... | |
using | menuBarCallback = std::function< bool(Component *caller, int index)> |
Used by a nkWinUi::MenuBar to signal an item has been clicked. More... | |
using | buttonClickCallback = std::function< bool(Button *caller)> |
Used by a nkWinUi::Button to signal it has been clicked. More... | |
using | checkBoxCallback = std::function< bool(CheckBox *caller)> |
Used by a nkWinUi::CheckBox to signal it has been checked / unchecked. More... | |
using | treeSelectionCallback = std::function< bool(TreeView *caller, void *itemData)> |
Used by a nkWinUi::TreeView to signal a selection occurred inside. More... | |
using | listBoxSelectionCallback = std::function< bool(ListBox *caller)> |
Used by a nkWinUi::ListBox to signal a selection occurred inside. More... | |
using | comboSelectionCallback = std::function< bool(ComboBox *caller)> |
Used by a nkWinUi::ComboBox to signal selection changed. More... | |
using | editBoxCharCallback = std::function< bool(EditBox *caller, const CharEventData &key)> |
Used by a nkWinUi::EditBox to signal a char has been put inside. More... | |
using | editBoxKeyCallback = std::function< bool(EditBox *caller, const KeyEventData &key)> |
Used by a nkWinUi::EditBox to signal a key has been pressed inside. More... | |
using | closeCallback = std::function< bool(Component *caller)> |
Used by a component to signal when it's closed. More... | |
using | resizeCallback = std::function< bool(Component *caller)> |
Used by a component upon resize. More... | |
using | contextMenuCreationCallback = std::function< bool(Component *caller, int absX, int absY)> |
Used by components when they need a context menu to be created. More... | |
typedef bool(* | runRoutine) () |
A callback for the running routine. Called when the loop from MainSystem::run() is running. | |
Enumerations | |
enum | COMPONENT_TYPE : unsigned int { COMPONENT_TYPE::BUTTON = 0, COMPONENT_TYPE::CHECK_BOX, COMPONENT_TYPE::COMBO_BOX, COMPONENT_TYPE::CONTEXT_MENU, COMPONENT_TYPE::EDIT_BOX, COMPONENT_TYPE::FILE_EXPLORER, COMPONENT_TYPE::GROUP_BOX, COMPONENT_TYPE::LIST_BOX, COMPONENT_TYPE::LOG_WIN, COMPONENT_TYPE::MULTI_LINE_EDIT, COMPONENT_TYPE::PROGRESS_BAR, COMPONENT_TYPE::SCROLL_BAR, COMPONENT_TYPE::SLIDER, COMPONENT_TYPE::STATIC, COMPONENT_TYPE::TAB_WIN, COMPONENT_TYPE::TOOL_BAR, COMPONENT_TYPE::TREE_VIEW, COMPONENT_TYPE::WINDOW } |
Available component types. More... | |
enum | ALIGNMENT { ALIGNMENT::TOP_LEFT = 0, ALIGNMENT::CENTER, ALIGNMENT::BOTTOM_RIGHT } |
Possible alignment values, interpretable by components depending on their behavior. More... | |
enum | BORDER_KIND { BORDER_KIND::TOP = 0, BORDER_KIND::LEFT, BORDER_KIND::BOTTOM, BORDER_KIND::RIGHT } |
Lists borders kind around components. More... | |
enum | RELATIVE_POSITION { RELATIVE_POSITION::UNKNOWN = 0, RELATIVE_POSITION::LEFT, RELATIVE_POSITION::RIGHT, RELATIVE_POSITION::TOP, RELATIVE_POSITION::BOTTOM, RELATIVE_POSITION::TOP_LEFT, RELATIVE_POSITION::TOP_RIGHT, RELATIVE_POSITION::BOTTOM_LEFT, RELATIVE_POSITION::BOTTOM_RIGHT } |
Possible relative positions of components. More... | |
enum | CHANGE_TYPE { CHANGE_TYPE::CHANGE_UNKNOWN = 0, CHANGE_TYPE::CHANGE_TEXT = 1, CHANGE_TYPE::CHANGE_NEW_UNDO = 2, CHANGE_TYPE::CHANGE_NEW_REDO = 4 } |
Describes a change nature. More... | |
enum | EVENT_TYPE { EVENT_TYPE::EVENT_UNKNOWN = 0, EVENT_TYPE::EVENT_MOUSE_CLICK, EVENT_TYPE::EVENT_MOUSE_MOVE, EVENT_TYPE::EVENT_MOUSE_WHEEL, EVENT_TYPE::EVENT_KEY } |
Represents an event type. More... | |
enum | MOUSE_BUTTON { MOUSE_BUTTON::MOUSE_LEFT = 0x0001, MOUSE_BUTTON::MOUSE_MIDDLE = 0x0010, MOUSE_BUTTON::MOUSE_RIGHT = 0x0002, MOUSE_BUTTON::MOUSE_X1 = 0x0020, MOUSE_BUTTON::MOUSE_X2 = 0x0040 } |
A mouse button identifier. More... | |
enum | KEY_CODE { KEY_UNKNOWN = 0, KEY_BACKSPACE = 0x08, KEY_TAB, KEY_CLEAR = 0x0C, KEY_RETURN, KEY_SHIFT = 0x10, KEY_CONTROL, KEY_MENU, KEY_PAUSE, KEY_CAPITAL, KEY_KANA, KEY_KANJI = 0x19, KEY_ESCAPE = 0x1B, KEY_SPACE = 0x20, KEY_UP_PAGE, KEY_DOWN_PAGE, KEY_END, KEY_HOME, KEY_LEFT, KEY_UP, KEY_RIGHT, KEY_DOWN, KEY_SELECT, KEY_PRINT, KEY_EXEC, KEY_PRINT_SCREEN, KEY_INSERT, KEY_DEL, KEY_HELP, KEY_0, KEY_1, KEY_2, KEY_3, KEY_4, KEY_5, KEY_6, KEY_7, KEY_8, KEY_9, KEY_A = 0x41, KEY_B, KEY_C, KEY_D, KEY_E, KEY_F, KEY_G, KEY_H, KEY_I, KEY_J, KEY_K, KEY_L, KEY_M, KEY_N, KEY_O, KEY_P, KEY_Q, KEY_R, KEY_S, KEY_T, KEY_U, KEY_V, KEY_W, KEY_X, KEY_Y, KEY_Z, KEY_LEFT_WINDOWS, KEY_RIGHT_WINDOWS, KEY_APPS, KEY_SLEEP = 0x5F, KEY_0_NUMPAD, KEY_1_NUMPAD, KEY_2_NUMPAD, KEY_3_NUMPAD, KEY_4_NUMPAD, KEY_5_NUMPAD, KEY_6_NUMPAD, KEY_7_NUMPAD, KEY_8_NUMPAD, KEY_9_NUMPAD, KEY_MULT, KEY_ADD, KEY_SEPARATOR, KEY_SUBSTRACT, KEY_DECIMAL, KEY_DIVIDE, KEY_F1 } |
A key code identifier. More... | |
enum | LAYOUT_TYPE { LAYOUT_TYPE::UNKNOWN = 0, LAYOUT_TYPE::GRID, LAYOUT_TYPE::RELATIVE } |
Defines the type of layout available. More... | |
Encompasses all API of component NilkinsWinUi.
This component offers capabilities to create and populate windows from the system UI. Note that currently, only supported system is Windows through the WinAPI.
To start with the component, first take a look at the nkWinUi::MainSystem to trigger all required initialization steps. Then, check the nkWinUi::ComponentManager to start creating nkWinUi::Component to interact with. Don't forget to check available nkWinUi::Layout to help with components composition.
using nkWinUi::mouseMoveCallback = typedef std::function<bool (Component* caller, int absX, int absY, int relX, int relY, int moveX, int moveY)> |
Used by components for a mouse moved event.
The callback will be called by the component, which will provide all the parameters about the event.
caller | The calling component. |
absX | The mouse x coordinate, absolute, on screen. |
absY | The mouse y coordinate, absolute, on screen. |
relX | The mouse x coordinate, relative to calling component. |
relY | The mouse y coordinate, relative to calling component. |
moveX | The x delta since last mouse moved event. |
moveY | the y delta since last mouse moved event. |
using nkWinUi::mouseClickCallback = typedef std::function<bool (Component* caller, const ClickEventData& eventData)> |
Used by components for a mouse click event.
The callback will be called by the component, which will provide all the parameters about the event.
caller | The calling component. |
eventData | All needed information about the event. |
using nkWinUi::mouseLeaveCallback = typedef std::function<bool (Component* caller, const nkMaths::Point& absCoords)> |
Used by components when the mouse leaves their area.
The callback will be called by the component, which will provide all the parameters about the event.
caller | The calling component. |
absCoords | The absolute coordinates at which the mouse left the component. |
using nkWinUi::keyDownCallback = typedef std::function<bool (Component* caller, KEY_CODE keyCode, bool autoRepeated)> |
Used by component when a keyboard key is pressed down.
The callback will be called by the component, which will provide all the parameters about the event.
caller | The calling component. |
keyCode | The code of the key pushed. |
autoRepeated | Whether this event is fired because the key is being auto repeated (long press). |
using nkWinUi::keyUpCallback = typedef std::function<bool (Component* caller, KEY_CODE keyCode)> |
Used by component when a keyboard key is released.
The callback will be called by the component, which will provide all the parameters about the event.
caller | The calling component. |
The | code of the key released. |
using nkWinUi::menuBarCallback = typedef std::function<bool (Component* caller, int index)> |
Used by a nkWinUi::MenuBar to signal an item has been clicked.
caller | The calling component. |
index | The index attached to the item clicked. |
using nkWinUi::buttonClickCallback = typedef std::function<bool (Button* caller)> |
Used by a nkWinUi::Button to signal it has been clicked.
caller | The calling component. |
using nkWinUi::checkBoxCallback = typedef std::function<bool (CheckBox* caller)> |
Used by a nkWinUi::CheckBox to signal it has been checked / unchecked.
The | calling component. Its state will reflect the new change. |
using nkWinUi::treeSelectionCallback = typedef std::function<bool (TreeView* caller, void* itemData)> |
Used by a nkWinUi::TreeView to signal a selection occurred inside.
caller | The calling component. |
itemData | The user data attached to the item selected. |
using nkWinUi::listBoxSelectionCallback = typedef std::function<bool (ListBox* caller)> |
Used by a nkWinUi::ListBox to signal a selection occurred inside.
caller | The calling component. Its state will reflect the new change. |
using nkWinUi::comboSelectionCallback = typedef std::function<bool (ComboBox* caller)> |
Used by a nkWinUi::ComboBox to signal selection changed.
The | calling component. Its state will reflect the new change. |
using nkWinUi::editBoxCharCallback = typedef std::function<bool (EditBox* caller, const CharEventData& key)> |
Used by a nkWinUi::EditBox to signal a char has been put inside.
caller | The calling component. |
key | The information about the event. |
using nkWinUi::editBoxKeyCallback = typedef std::function<bool (EditBox* caller, const KeyEventData& key)> |
Used by a nkWinUi::EditBox to signal a key has been pressed inside.
caller | The calling component. |
key | The information about the event. |
using nkWinUi::closeCallback = typedef std::function<bool (Component* caller)> |
Used by a component to signal when it's closed.
caller | The calling component. |
using nkWinUi::resizeCallback = typedef std::function<bool (Component* caller)> |
Used by a component upon resize.
caller | The calling component. |
using nkWinUi::contextMenuCreationCallback = typedef std::function<bool (Component* caller, int absX, int absY)> |
Used by components when they need a context menu to be created.
caller | The calling component. |
absX | The absolute x position where the menu should be created. |
absY | The absolute y position where the menu should be created. |
|
strong |
Available component types.
Enumerator | |
---|---|
BUTTON | A Button. |
CHECK_BOX | A CheckBox. |
COMBO_BOX | A ComboBox. |
CONTEXT_MENU | A ContextMenu. |
EDIT_BOX | An EditBox. |
FILE_EXPLORER | A FileExplorer. |
GROUP_BOX | A GroupBox. |
LIST_BOX | A ListBox. |
LOG_WIN | A LogWin. |
MULTI_LINE_EDIT | |
PROGRESS_BAR | A ProgressBar. |
SCROLL_BAR | A ScrollBar. |
SLIDER | A Slider. |
STATIC | A Static. |
TAB_WIN | A TabWindow. |
TOOL_BAR | A ToolBar. |
TREE_VIEW | A TreeView. |
WINDOW | A Window. |
|
strong |
|
strong |
|
strong |
|
strong |
|
strong |
|
strong |
enum nkWinUi::KEY_CODE |
|
strong |
Defines the type of layout available.
Enumerator | |
---|---|
UNKNOWN | A Layout whose type is unknown. Should never be encountered. |
GRID | A grid layout. |
RELATIVE | A relative layout. |